<!-- HTML header for doxygen 1.8.14-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.9.1"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>Unity ML-Agents Toolkit: SensorComponent Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygenbase.css" rel="stylesheet" type="text/css" />
<link href="unity.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="logo.png"/></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">Unity ML-Agents Toolkit
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.9.1 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search','.html');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(document).ready(function(){initNavTree('classUnity_1_1MLAgents_1_1Sensors_1_1SensorComponent.html',''); initResizable(); });
/* @license-end */
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="classUnity_1_1MLAgents_1_1Sensors_1_1SensorComponent-members.html">List of all members</a>  </div>
  <div class="headertitle">
<div class="title">SensorComponent Class Reference<span class="mlabels"><span class="mlabel">abstract</span></span></div>  </div>
</div><!--header-->
<div class="contents">

<p>Editor components for creating <a class="el" href="namespaceUnity_1_1MLAgents_1_1Sensors.html">Sensors</a>.  
 <a href="classUnity_1_1MLAgents_1_1Sensors_1_1SensorComponent.html#details">More...</a></p>

<p>Inherits MonoBehaviour.</p>

<p>Inherited by <a class="el" href="classUnity_1_1MLAgents_1_1Sensors_1_1CameraSensorComponent.html">CameraSensorComponent</a>, <a class="el" href="classUnity_1_1MLAgents_1_1Sensors_1_1RayPerceptionSensorComponentBase.html">RayPerceptionSensorComponentBase</a>, and <a class="el" href="classUnity_1_1MLAgents_1_1Sensors_1_1RenderTextureSensorComponent.html">RenderTextureSensorComponent</a>.</p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:ae7a70aadeb77bfc40ec5d011b6e46939"><td class="memItemLeft" align="right" valign="top">abstract <a class="el" href="interfaceUnity_1_1MLAgents_1_1Sensors_1_1ISensor.html">ISensor</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classUnity_1_1MLAgents_1_1Sensors_1_1SensorComponent.html#ae7a70aadeb77bfc40ec5d011b6e46939">CreateSensor</a> ()</td></tr>
<tr class="memdesc:ae7a70aadeb77bfc40ec5d011b6e46939"><td class="mdescLeft">&#160;</td><td class="mdescRight">Create the <a class="el" href="interfaceUnity_1_1MLAgents_1_1Sensors_1_1ISensor.html" title="Sensor interface for generating observations.">ISensor</a>.  <a href="classUnity_1_1MLAgents_1_1Sensors_1_1SensorComponent.html#ae7a70aadeb77bfc40ec5d011b6e46939">More...</a><br /></td></tr>
<tr class="separator:ae7a70aadeb77bfc40ec5d011b6e46939"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a09a2b457d79bfe4088618f3f7e954a6c"><td class="memItemLeft" align="right" valign="top">abstract int[]&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classUnity_1_1MLAgents_1_1Sensors_1_1SensorComponent.html#a09a2b457d79bfe4088618f3f7e954a6c">GetObservationShape</a> ()</td></tr>
<tr class="memdesc:a09a2b457d79bfe4088618f3f7e954a6c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the shape of the sensor observations that will be created.  <a href="classUnity_1_1MLAgents_1_1Sensors_1_1SensorComponent.html#a09a2b457d79bfe4088618f3f7e954a6c">More...</a><br /></td></tr>
<tr class="separator:a09a2b457d79bfe4088618f3f7e954a6c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9fcfcdf5ac3113dcc660dfb9a5c2e581"><td class="memItemLeft" align="right" valign="top">virtual bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classUnity_1_1MLAgents_1_1Sensors_1_1SensorComponent.html#a9fcfcdf5ac3113dcc660dfb9a5c2e581">IsVisual</a> ()</td></tr>
<tr class="memdesc:a9fcfcdf5ac3113dcc660dfb9a5c2e581"><td class="mdescLeft">&#160;</td><td class="mdescRight">Whether the observation is visual or not.  <a href="classUnity_1_1MLAgents_1_1Sensors_1_1SensorComponent.html#a9fcfcdf5ac3113dcc660dfb9a5c2e581">More...</a><br /></td></tr>
<tr class="separator:a9fcfcdf5ac3113dcc660dfb9a5c2e581"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af41da8555b5d967ab1bf7d4981da0110"><td class="memItemLeft" align="right" valign="top">virtual bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classUnity_1_1MLAgents_1_1Sensors_1_1SensorComponent.html#af41da8555b5d967ab1bf7d4981da0110">IsVector</a> ()</td></tr>
<tr class="memdesc:af41da8555b5d967ab1bf7d4981da0110"><td class="mdescLeft">&#160;</td><td class="mdescRight">Whether the observation is vector or not.  <a href="classUnity_1_1MLAgents_1_1Sensors_1_1SensorComponent.html#af41da8555b5d967ab1bf7d4981da0110">More...</a><br /></td></tr>
<tr class="separator:af41da8555b5d967ab1bf7d4981da0110"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Editor components for creating <a class="el" href="namespaceUnity_1_1MLAgents_1_1Sensors.html">Sensors</a>. </p>
<p>Generally an <a class="el" href="interfaceUnity_1_1MLAgents_1_1Sensors_1_1ISensor.html" title="Sensor interface for generating observations.">ISensor</a> implementation should have a corresponding <a class="el" href="classUnity_1_1MLAgents_1_1Sensors_1_1SensorComponent.html" title="Editor components for creating Sensors.">SensorComponent</a> to create it.</p>
</div><h2 class="groupheader">Member Function Documentation</h2>
<a id="ae7a70aadeb77bfc40ec5d011b6e46939"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae7a70aadeb77bfc40ec5d011b6e46939">&#9670;&nbsp;</a></span>CreateSensor()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">abstract <a class="el" href="interfaceUnity_1_1MLAgents_1_1Sensors_1_1ISensor.html">ISensor</a> CreateSensor </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">pure virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Create the <a class="el" href="interfaceUnity_1_1MLAgents_1_1Sensors_1_1ISensor.html" title="Sensor interface for generating observations.">ISensor</a>. </p>
<p>This is called by the <a class="el" href="classUnity_1_1MLAgents_1_1Agent.html" title="An agent is an actor that can observe its environment, decide on the best course of action using thos...">Agent</a> when it is initialized.</p>
<dl class="section return"><dt>Returns</dt><dd>Created <a class="el" href="interfaceUnity_1_1MLAgents_1_1Sensors_1_1ISensor.html" title="Sensor interface for generating observations.">ISensor</a> object.</dd></dl>

<p>Implemented in <a class="el" href="classUnity_1_1MLAgents_1_1Sensors_1_1RenderTextureSensorComponent.html#af33001bb7f674c75660373e7694ab5ec">RenderTextureSensorComponent</a>, <a class="el" href="classUnity_1_1MLAgents_1_1Sensors_1_1RayPerceptionSensorComponentBase.html#af33001bb7f674c75660373e7694ab5ec">RayPerceptionSensorComponentBase</a>, and <a class="el" href="classUnity_1_1MLAgents_1_1Sensors_1_1CameraSensorComponent.html#af33001bb7f674c75660373e7694ab5ec">CameraSensorComponent</a>.</p>

</div>
</div>
<a id="a09a2b457d79bfe4088618f3f7e954a6c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a09a2b457d79bfe4088618f3f7e954a6c">&#9670;&nbsp;</a></span>GetObservationShape()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">abstract int [] GetObservationShape </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">pure virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Returns the shape of the sensor observations that will be created. </p>
<dl class="section return"><dt>Returns</dt><dd>Shape of the sensor observation.</dd></dl>

<p>Implemented in <a class="el" href="classUnity_1_1MLAgents_1_1Sensors_1_1RenderTextureSensorComponent.html#a3d76391747ede7e0abbe3b7d7f4a73f4">RenderTextureSensorComponent</a>, <a class="el" href="classUnity_1_1MLAgents_1_1Sensors_1_1RayPerceptionSensorComponentBase.html#a3d76391747ede7e0abbe3b7d7f4a73f4">RayPerceptionSensorComponentBase</a>, and <a class="el" href="classUnity_1_1MLAgents_1_1Sensors_1_1CameraSensorComponent.html#a3d76391747ede7e0abbe3b7d7f4a73f4">CameraSensorComponent</a>.</p>

</div>
</div>
<a id="af41da8555b5d967ab1bf7d4981da0110"></a>
<h2 class="memtitle"><span class="permalink"><a href="#af41da8555b5d967ab1bf7d4981da0110">&#9670;&nbsp;</a></span>IsVector()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual bool IsVector </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Whether the observation is vector or not. </p>
<dl class="section return"><dt>Returns</dt><dd>True if the observation is vector, false otherwise.</dd></dl>

</div>
</div>
<a id="a9fcfcdf5ac3113dcc660dfb9a5c2e581"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a9fcfcdf5ac3113dcc660dfb9a5c2e581">&#9670;&nbsp;</a></span>IsVisual()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">virtual bool IsVisual </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Whether the observation is visual or not. </p>
<dl class="section return"><dt>Returns</dt><dd>True if the observation is visual, false otherwise.</dd></dl>

</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="SensorComponent_8cs.html">SensorComponent.cs</a></li>
</ul>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- HTML footer for doxygen 1.8.14-->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="namespaceUnity.html">Unity</a></li><li class="navelem"><a class="el" href="namespaceUnity_1_1MLAgents.html">MLAgents</a></li><li class="navelem"><a class="el" href="namespaceUnity_1_1MLAgents_1_1Sensors.html">Sensors</a></li><li class="navelem"><a class="el" href="classUnity_1_1MLAgents_1_1Sensors_1_1SensorComponent.html">SensorComponent</a></li>
  </ul>
</div>
</body>
</html>
